"use strict";

var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");

require("core-js/modules/es.function.name");

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.NotImplementedException = exports.InvalidArgumentException = exports.IllegalStateException = exports.RuntimeException = void 0;

var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/inherits"));

var _possibleConstructorReturn2 = _interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));

var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));

var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));

var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));

function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }

function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }

/*
 * Copyright (C) 2016 Bilibili. All Rights Reserved.
 *
 * @author zheng qian <xqq@xqq.im>
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
var RuntimeException = /*#__PURE__*/function () {
  function RuntimeException(message) {
    (0, _classCallCheck2.default)(this, RuntimeException);
    this._message = message;
  }

  (0, _createClass2.default)(RuntimeException, [{
    key: "toString",
    value: function toString() {
      return this.name + ': ' + this.message;
    }
  }, {
    key: "name",
    get: function get() {
      return 'RuntimeException';
    }
  }, {
    key: "message",
    get: function get() {
      return this._message;
    }
  }]);
  return RuntimeException;
}();

exports.RuntimeException = RuntimeException;

var IllegalStateException = /*#__PURE__*/function (_RuntimeException) {
  (0, _inherits2.default)(IllegalStateException, _RuntimeException);

  var _super = _createSuper(IllegalStateException);

  function IllegalStateException(message) {
    (0, _classCallCheck2.default)(this, IllegalStateException);
    return _super.call(this, message);
  }

  (0, _createClass2.default)(IllegalStateException, [{
    key: "name",
    get: function get() {
      return 'IllegalStateException';
    }
  }]);
  return IllegalStateException;
}(RuntimeException);

exports.IllegalStateException = IllegalStateException;

var InvalidArgumentException = /*#__PURE__*/function (_RuntimeException2) {
  (0, _inherits2.default)(InvalidArgumentException, _RuntimeException2);

  var _super2 = _createSuper(InvalidArgumentException);

  function InvalidArgumentException(message) {
    (0, _classCallCheck2.default)(this, InvalidArgumentException);
    return _super2.call(this, message);
  }

  (0, _createClass2.default)(InvalidArgumentException, [{
    key: "name",
    get: function get() {
      return 'InvalidArgumentException';
    }
  }]);
  return InvalidArgumentException;
}(RuntimeException);

exports.InvalidArgumentException = InvalidArgumentException;

var NotImplementedException = /*#__PURE__*/function (_RuntimeException3) {
  (0, _inherits2.default)(NotImplementedException, _RuntimeException3);

  var _super3 = _createSuper(NotImplementedException);

  function NotImplementedException(message) {
    (0, _classCallCheck2.default)(this, NotImplementedException);
    return _super3.call(this, message);
  }

  (0, _createClass2.default)(NotImplementedException, [{
    key: "name",
    get: function get() {
      return 'NotImplementedException';
    }
  }]);
  return NotImplementedException;
}(RuntimeException);

exports.NotImplementedException = NotImplementedException;